<div class="form_item_block <%= scope[:on_cancel] ? "on_cancel_" : "" -%>run_if_options" id="<%= scope[:runif_container] = random_dom_id('run_if_options_') -%>">
    <label><%== required_label_text('Run If Conditions') -%></label>

    <%= scope[:form].check_box com.thoughtworks.go.config.AbstractTask::RUN_IF_CONFIGS_PASSED, {:class => "runif passed", :include_hidden => false, :id => scope[:run_if] = random_dom_id("runif_passed_")} %>
    <%= label_tag scope[:run_if], h('Passed'), :class => "condition" -%>

    <%= scope[:form].check_box com.thoughtworks.go.config.AbstractTask::RUN_IF_CONFIGS_FAILED, {:class => "runif failed", :include_hidden => false, :id => scope[:run_if] = random_dom_id("runif_failed_")} %>
    <%= label_tag scope[:run_if], h('Failed'), :class => "condition" -%>

    <%= scope[:form].check_box com.thoughtworks.go.config.AbstractTask::RUN_IF_CONFIGS_ANY, {:class => "runif any", :include_hidden => false, :id => scope[:run_if] = random_dom_id("runif_any_")} %>
    <%= label_tag scope[:run_if], h('Any'), :class => "condition" -%>

    <script type="text/javascript">
        Util.on_load(function() {
            new TaskEditor.RunIfEditor(jQuery("#<%= scope[:runif_container] -%>"));
        });
    </script>
</div>